/**
 * jims
 */
package com.jims.master.modules.sync.dao;

import com.jims.master.common.persistence.CrudDao;
import com.jims.master.common.persistence.annotation.MyBatisDao;
import com.jims.master.modules.sync.entity.ExamApply;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * 检查申请DAO接口
 * @author 陈晓阳
 * @version 2017-03-14
 */
@MyBatisDao
public interface ExamApplyDao extends CrudDao<ExamApply> {
    /**
     * 根据Id删除
     * @param id
     * @return
     */
    public int deleteById(@Param("id") String id);

    /**
     * 执行确认操作
     * @param id
     * @return
     */
    public int examConfirmDo(@Param("id") String id, @Param("userId") String userId);

    /**
     * 医技取消确认操作
     * @param id
     * @param userId
     * @return int
     * @author 赵宁
     */
    public int cancelExamConfirmDo(@Param("id") String id, @Param("userId") String userId);

    /**
     * 检查确认==住院
     * @param examApply
     * @return
     * @author 赵宁
     */
    public int examConfirmInHos(ExamApply examApply);

    /**
     * 取消检查确认=住院
     * @param examApply
     * @return
     * @author 赵宁
     */
    public int cancelExamConfirmInHos(ExamApply examApply);

    /**
     * 退费中
     * @param examApply
     * @return
     */
    public int refundIng(ExamApply examApply);

    /**
     * 医生端--检查查询
     * @param clinicId
     * @return
     * @author 赵宁
     */
    public List<ExamApply> getByClinicId(@Param("clinicId") String clinicId);

    /**
     * 护士端--未尽检查查询
     * @param visitId
     * @return
     * @author 赵宁
     */
    public List<ExamApply> getUnfinished(@Param("visitId") String visitId);

    /**
     * 住院退费申请
     * @param id
     * @return
     */
    public int inpOutpRet(@Param("chargeFlag") String chargeFlag, @Param("id") String id);

    public ExamApply getApply(@Param("ordersId") String ordersId);

    public int delApply(@Param("ordersId") String ordersId);

}